package xyz.renyumeng.xkm.es.service;

import xyz.renyumeng.xkm.dto.base.SearchPage;
import xyz.renyumeng.xkm.model.es.EsProduct;

import java.util.List;

/**
 * @author renyumeng
 * @date Created in 20:14 2023/7/3
 */
public interface EsShopService {

    SearchPage<List<EsProduct>> searchProduct(String key, int page, int size);

    int importAll();

    EsProduct save(EsProduct esProduct);

    EsProduct getEsProductById(Long productId);

    SearchPage<List<EsProduct>> pageByOwnerId(Integer page, Integer size, Long ownerId);

    SearchPage<List<EsProduct>> pageByOwnerIdIsSole(Integer page, Integer size, Long ownerId,Integer isSole);

    Boolean getEsProductIdWithIsListed(Long productId, Integer isListed);
}
